package com.tbit.uqbike.service.business;

import com.baomidou.mybatisplus.extension.service.IService;
import com.tbit.uqbike.object.pojo.UpgradeDetail;
import com.tbit.uqbike.object.pojo.UpgradeMachine;
import com.tbit.uqbike.object.pojo.dto.UpgradeDTO;
import com.tbit.uqbike.object.pojo.vo.UpgradeVO;
import com.tbit.uqbike.object.value.LoginInfo;
import com.tbit.common.entity.view.PageResult;
import com.tbit.common.entity.view.Result;
import org.springframework.web.multipart.MultipartFile;

import java.util.List;

/**
 * 升级车辆service
 *
 * @author <a href="mailto:liu.haoxiang@tbit.com.cn">BUGXiang</a>
 * @version 1.0
 * @since 2024/3/15
 */
public interface UpgradeService extends IService<UpgradeMachine> {

    /**
     * 分页查询车辆列表
     *
     * @param upgradeDTO upgradeDTO
     * @return Result<PageInfo < UpgradeVO>>
     */
    Result<PageResult<UpgradeVO>> queryPage(UpgradeDTO upgradeDTO);

    /**
     * 导入车辆
     *
     * @param file      excel
     * @param accountId 区域id
     * @param login     login
     * @return Result<Object>
     */
    Result<Object> importFile(MultipartFile file, Integer accountId, LoginInfo login);

    /**
     * 导出升级车辆信息
     *
     * @param upgradeDTO upgradeDTO
     * @return excel
     */
    Result<Object> exportFile(UpgradeDTO upgradeDTO);

    /**
     * 删除车辆
     *
     * @param upgradeId 车辆id
     */
    void deleteId(Integer upgradeId);

    /**
     * 升级详情
     *
     * @param upgradeId 升级车辆id
     * @return result
     */
    Result<PageResult<UpgradeDetail>> detail(Integer upgradeId, Integer accountId, Integer pageNumber, Integer size);
}
